Update custom point type doc (4th coordinate is not set to 1)#6362
Update custom point type doc (4th coordinate is not set to 1)#6362themightyoarfish wants to merge 5 commits into
Conversation
… behave as expected for custom point types without additional constructors
|
How can i re-run the checks? Cant see why CI cannot build it. |
|
Since the CI logs keep getting deleted after 2 weeks or so: Honestly not sure how to solve this. Maybe adding a note to the documentation instead is sufficient? |
|
It seems to build with the latest change. I can't explain the previous error either, but initializing the |
|
Nevermind, the change fixes build on gcc/clang, but msvc is still unhappy. |
wat |
0c3c3c1 to
639f9fa
Compare
|
I am also unsuccessfull reproducing this with godbolt: https://godbolt.org/z/hKnb1KWzr it compiles and runs normally in x64 msvc, but does not even run with x86 msvc, but also no compile error. Maybe we need the same compile flags which the PCL CI uses, but i think I won't be able to fix this, since i don't know anything about windows development. we could add a hint in the documentation, but i doubt this will save anyone from wasting many hours on this before they think to look there. |
639f9fa to
68da5a0
Compare
themightyoarfish
left a comment
There was a problem hiding this comment.
gemini says that msvc does not handle default initializers inside unions inside macros, even though this is allegedly legal as of c++11
ca4f92e to
d3c3ca0
Compare
d3c3ca0 to
fb347b7
Compare
|
There seems to be no way without changing a bunch of PCL code to default-initialize the 4th coordinate to 1. I also tried everything suggested by gemini, but anything that made GCC/clang happy would still fail on msvc. So instead i updated the custom point type tutorial. |
|
(please squash the irrelevant history when merging) |
The 4th homogeneous coordinate of custom point types is not set to 1.
Got bitten by this since i made a custom point type without custom constructor and a library was expecting the points to be homogeneous and computed hard to debug garbage.